#include <iostream>

int main() {
    FILE *read_fp;
    char buffer[201];
    int chars_read;
    memset(buffer, '\0', sizeof(buffer));

    read_fp = popen("uname -a", "r");
    if (read_fp != NULL) {
        chars_read = fread(buffer, sizeof(char), 200, read_fp);
        if (chars_read > 0) {
            printf("Output was:-\n%s\n", buffer);
        }
        pclose(read_fp);
        return 0;
    }

    return 0;
}
